package com.example.LibrarySystem.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

@TableName("users")
public class User {
    /**
     *TableId: mybatisplus 主键id 注解
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    private String account;
    private String password;
    private String roleName;
    private boolean status;
    private String name;
    private Date creationTime;
    private String sno;
    private Integer classId;

    public User() {
    }

    public User(Integer id, String account, String password, String roleName, boolean status, String name, Date creationTime, String sno, Integer classId) {
        this.id = id;
        this.account = account;
        this.password = password;
        this.roleName = roleName;
        this.status = status;
        this.name = name;
        this.creationTime = creationTime;
        this.sno = sno;
        this.classId = classId;
    }


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public boolean isStatus() {
        return status;
    }

    public void setStatus(boolean status) {
        this.status = status;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Date getCreationTime() {
        return creationTime;
    }

    public void setCreationTime(Date creationTime) {
        this.creationTime = creationTime;
    }

    public String getSno() {
        return sno;
    }

    public void setSno(String sno) {
        this.sno = sno;
    }

    public Integer getClassId() {
        return classId;
    }

    public void setClassId(Integer classId) {
        this.classId = classId;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", account='" + account + '\'' +
                ", password='" + password + '\'' +
                ", roleName='" + roleName + '\'' +
                ", status=" + status +
                ", name='" + name + '\'' +
                ", creationTime=" + creationTime +
                ", sno='" + sno + '\'' +
                ", classId=" + classId +
                '}';
    }
}

